package com.easytouch.core.ftp;

import java.util.EventListener;
import java.util.Iterator;

public class CopyStreamAdapter implements CopyStreamListener {
    private final ListenerList internalListeners = new ListenerList();

    public CopyStreamAdapter() {
    }

    public void bytesTransferred(CopyStreamEvent event) {
        Iterator i$ = this.internalListeners.iterator();

        while(i$.hasNext()) {
            EventListener listener = (EventListener)i$.next();
            ((CopyStreamListener)((CopyStreamListener)listener)).bytesTransferred(event);
        }

    }

    public void bytesTransferred(long totalBytesTransferred, int bytesTransferred, long streamSize) {
        Iterator i$ = this.internalListeners.iterator();

        while(i$.hasNext()) {
            EventListener listener = (EventListener)i$.next();
            ((CopyStreamListener)((CopyStreamListener)listener)).bytesTransferred(totalBytesTransferred, bytesTransferred, streamSize);
        }

    }

    public void addCopyStreamListener(CopyStreamListener listener) {
        this.internalListeners.addListener(listener);
    }

    public void removeCopyStreamListener(CopyStreamListener listener) {
        this.internalListeners.removeListener(listener);
    }
}

